package com.aispeech.testcustom.bean;

import android.util.Log;

/**
 * Created by rain on 2016/12/14.
 */
public class AISampleRate {
    private static final String a = AISampleRate.class.getName();
    public static final String KEY_SAMPLE_RATE = "sampleRate";
    public static final AISampleRate SAMPLE_RATE_16K = new AISampleRate(16000);
    public static final AISampleRate SAMPLE_RATE_8K = new AISampleRate(8000);
    private int sampleRate;

    public static AISampleRate toAISampleRate(int var0) {
        if(var0 == SAMPLE_RATE_16K.getValue()) {
            return SAMPLE_RATE_16K;
        } else if(var0 == SAMPLE_RATE_8K.getValue()) {
            return SAMPLE_RATE_8K;
        } else {
            Log.d("test", "toAISampleRate: Unsupported sampleRate!");
            return null;
        }
    }

    private AISampleRate(int var1) {
        this.sampleRate = var1;
    }

    public int getValue() {
        return this.sampleRate;
    }

    public boolean equals(Object var1) {
        return var1 == this;
    }
}
